<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:s="http://jboss.com/products/seam/taglib"
	xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html" xmlns:r="http://richfaces.org/rich" xmlns:a="http://richfaces.org/a4j" 
	xmlns:ad="http://agiledev.com.br/fieldset">
	
	<ad:fieldset legenda="#{messages.login}">		

		<h:form id="loginForm">

			<s:decorate template="/layout/edit.xhtml">
				<ui:define name="label">
					<h:outputText value="#{messages.usuario}" />
				</ui:define>
				<h:inputText id="usuario" value="#{credentials.username}" size="20" maxlength="20" required="true">
					<f:validateLength maximum="20" />
				</h:inputText>
			</s:decorate>
			
			<s:decorate template="/layout/edit.xhtml">
				<ui:define name="label">
					<h:outputText value="#{messages.senha}" />
				</ui:define>
				<h:inputSecret id="senha" value="#{credentials.password}" size="20" maxlength="20" required="true">
					<f:validateLength maximum="20" />
				</h:inputSecret>
			</s:decorate>
			
			<s:decorate template="/layout/edit.xhtml">
				<ui:define name="label">
					<h:outputText value="#{messages.lembrarMe}" />
				</ui:define>
				<h:selectBooleanCheckbox id="rememberMe" value="#{rememberMe.enabled}" />
			</s:decorate>
			
			<div>
				<span style="float: left; clear: left;">
					<a:commandButton value="#{messages.logar}" action="#{identity.login}"/>
				</span>
			</div>
		</h:form>
	</ad:fieldset>
</ui:composition>